package org.example.springbook.service;

import org.example.springbook.mapper.BookInfoMapper;
import org.example.springbook.mapper.UserInfoMapper;
import org.example.springbook.model.UserInfo;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
public class UserService {
    @Autowired
    private UserInfoMapper userInfoMapper;
    // 那么UserService 也要提供一个方法
    public UserInfo getUserInfoByName(String name){
        return userInfoMapper.selectUserByName(name);
    }
}
